package com.didispace.web;


import java.util.Map;



import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;

import org.springframework.stereotype.Controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.support.RequestContextUtils;



import java.util.Locale;
import javax.annotation.Resource;
import org.springframework.context.MessageSource;
import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.stereotype.Component;

import com.domain.User;


 
@Controller
public class DoController {
	
	
	//@Value("${application.hello:Hello Angel}")

    private String hello;
	
	@Autowired
	private MessageSource messageSource;
	
	

   

      

       @RequestMapping("/helloJsp")

       public String helloJsp(Map<String,Object> map){

              System.out.println("DoController.helloJsp().hello="+hello+"123我们");

              map.put("hello", hello);
              
              Locale locale = LocaleContextHolder.getLocale();  
             
           
              
              String msg = messageSource.getMessage("language.cn", null,locale);
              

              return "helloJsp";

       }
	
	
	

}
